package com.group.three.mapper;


import com.group.three.pojo.FavoriteVideos;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.transaction.annotation.Transactional;

import java.util.List;

/**
 * <p>
 * Mapper 接口
 * </p>
 *
 * @author xueyong
 * @since 2022-11-03
 */
@Mapper
public interface FavoriteVideosMapper {

    List<FavoriteVideos> selectFavoriteAll();

    int deleteFavoriteVideosId(Long favoriteVideosId);

    List<FavoriteVideos> selectAll();

    List<FavoriteVideos> searchByInput(String input);

    int insertVideo(@Param("favoriteVideosId") Long FavoriteVideosId,@Param("videoNumber") Long videoNumber,@Param("personId") Long personId,@Param("collectionTime")String collectionTime,Integer favoriteState);

    List<FavoriteVideos> selectIsFavorite(@Param("videoNumber") Long videoNumber,@Param("personId")Long personId, @Param("favoriteState")Integer favoriteState);

    List<FavoriteVideos> selectAdminFavoriteVideosId(Long personId);

    int deleteCancel(@Param("personId")Long personId,@Param("videoNumber")Long videoNumber);
}
